package com.work.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.work.Person;
import com.work.PersonA;
import com.work.tool.CryTool;
import com.work.tool.CryToolA;

@Configuration
public class BeanConfig {

	
	@Bean
	public Person person(){
		return  new PersonA(tool());
	}
	
	@Bean CryTool tool(){
		return new CryToolA(System.out);
	}
}
